﻿<?xml version="1.0" encoding="utf-8" ?>
<hibernate-mapping xmlns="urn:nhibernate-mapping-2.2" assembly="Lucid.ESA.ClientDataSystem.Domain" namespace="Lucid.ESA.ClientDataSystem.Domain.Entities">
  <class name="Client" table="`Client`">
    <id name="Id" column="`Id`" type="long">
      <generator class="identity" />
    </id>
    <property name="Name" column="`Name`" />
    <property name="Deleted" column="`Deleted`" />
    <bag name="Contacts" inverse="true" lazy="true" cascade="all">
      <key column="`ClientId`" />
      <one-to-many class="Contact" />
    </bag>
    <bag name="Sites" inverse="true" lazy="true" cascade="all">
      <key column="`ClientId`" />
      <one-to-many class="Site" />
    </bag>
  </class>
</hibernate-mapping>